package com.wangjiang.mario.admin.system.domain.service;

import com.wangjiang.mario.admin.common.base.BaseService;
import com.wangjiang.mario.admin.system.domain.entity.RoleEntity;
import com.wangjiang.mario.admin.system.object.role.RoleQo;
import com.wangjiang.mario.admin.system.object.role.RoleVo;

import java.util.List;

/**
 * 角色的Serivce接口
 *
 * @author wangjiang
 * @Date 2019-08-09 14:35:19
 */
public interface RoleService extends BaseService<RoleEntity> {

    Object basePageWithDept(Integer currentPage, Integer pageSize, RoleQo qo, Class<RoleVo> roleVoClass);

    /**
     * 给角色分配菜单权限
     * @param roleCode
     * @param menuIds
     * @return
     */
    Integer setRoleMenu(String roleCode, List<String> menuIds);

    Integer updateRoleMenu(String roleCode, List<String> menuCodes);

    List<String> getMenusByRoleCode(String roleCode);

    Boolean saveRole(RoleEntity roleEntity);

}
